package com.google.code.swingonfire.component.foldable;

import java.io.Serializable;

public class FoldableEvent implements Serializable
{

    private static final long serialVersionUID = -5371937742434855063L;

    private final Object source;
    private final double fraction;
    private final double interpolatedFraction;
    private final boolean folded;

    public FoldableEvent(Object source, double fraction, double interpolatedFraction, boolean folded)
    {
        super();

        this.source = source;
        this.fraction = fraction;
        this.interpolatedFraction = interpolatedFraction;
        this.folded = folded;
    }

    public Object getSource()
    {
        return source;
    }

    public double getFraction()
    {
        return fraction;
    }

    public double getInterpolatedFraction()
    {
        return interpolatedFraction;
    }

    public boolean isFolded()
    {
        return folded;
    }

}
